<link rel="stylesheet" href="app/collection/css/collection.css"/>
<div class="overview_main">
    <div class="col-sm-12">
        <div class="panel panel-default">
            <div class="panel-heading">
                <h3 class="panel-title">{{ collection.name }}</h3>
            </div>
            <div class="panel-body">
                <table class="table table-striped table-bordered table-hover">
                    <tr>
                        <th>名称</th>
                        <th>Shard</th>
                        <th>最后修改时间</th>
                        <th>文档数</th>
                        <th>最大文档数</th>
                        <th>已删除文档数</th>
                        <th>段数量</th>
                        <th>版本</th>
                    </tr>
                    <tr ng-repeat="replica in replicas">
                        <td>{{ replica.name }}</td>
                        <td>{{ replica.shard }}</td>
                        <td>{{ replica.lastModified | date: 'yyyy-MM-dd HH:mm:ss' }}</td>
                        <td>{{ replica.numDocs }}</td>
                        <td>{{ replica.maxDocs }}</td>
                        <td>{{ replica.deletedDocs }}</td>
                        <td>{{ replica.segmentCount }}</td>
                        <td>{{ replica.version }}</td>
                    </tr>
                    <tr>
                        <td colspan="2">{{ collection.name }} 总计：</td>
                        <td>{{ collection.lastModified | date: 'yyyy-MM-dd HH:mm:ss' }}</td>
                        <td>{{ collection.numDocs }}</td>
                        <td>{{ collection.maxDocs }}</td>
                        <td>{{ collection.deletedDocs }}</td>
                        <td>{{ collection.segmentCount }}</td>
                        <td></td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
    <div class="col-sm-6">
        <div class="panel panel-default" ng-controller="GlobalController">
            <div class="panel-heading">
                <h3 class="panel-title">QPS</h3>
            </div>
            <div class="panel-body" ng-controller="QpsController" ng-init="getOverviewQpsStat(collectionId)">
                <div id="qpsChart" class="panel-chart"></div>
            </div>
        </div>
    </div>
    <div class="col-sm-6">
        <div class="panel panel-default" ng-controller="GlobalController">
            <div class="panel-heading">
                <h3 class="panel-title">数据增长</h3>
            </div>
            <div class="panel-body" ng-controller="GrowController" ng-init="getOverviewGrowStat(collectionId)">
                <div id="growChart" class="panel-chart"></div>
            </div>
        </div>
    </div>
</div>